package kr.co.shoppingmall.admin;

import java.util.HashMap;
import java.util.List;

public class AdminServiceImpl implements AdminService {
    private AdminDAO adminDAO;

    public void setAdminDAO(AdminDAO adminDAO) {
	this.adminDAO = adminDAO;
    }

    @Override
    public void insertProduct(ProductDTO dto) {
	adminDAO.insertProduct(dto);
    }

    @Override
    public List<ProductDTO> getProductList(HashMap map) {
	return adminDAO.getProductList(map);
    }

    @Override
    public int getProductCount() {
	return adminDAO.getProductCount();
    }

    @Override
    public ProductDTO getProduct(String prodCode) {
	return (ProductDTO) adminDAO.getProduct(prodCode);
    }

    @Override
    public void updateProduct(ProductDTO dto) {
	adminDAO.updateProduct(dto);
    }

    @Override
    public void deleteProduct(String prodCode) {
	adminDAO.deleteProduct(prodCode);
    }
}
